<?php
App::uses('AppModel', 'Model');
/**
 * Answer Model
 *
 * @property question $question
 */
class Answer extends AppModel {

/**
 * Primary key field
 *
 * @var string
 */
	public $primaryKey = 'answers_id';


	public $validate = array(
        
        'answers' => array( 
            'answer_must_be_entered' => array( 
            'rule' => array('notempty'), 
            'message' => 'Please enter an answer'), 
       ),
    );

/**
 * Display field
 *
 * @var string
 */
	public $displayField = 'answers';


	//The Associations below have been created with all possible keys, those that are not needed can be removed

/**
 * hasMany associations
 *
 * @var array
 */
	public $hasMany = array(
		'question' => array(
			'className' => 'question',
			'foreignKey' => 'answers_id',
			'dependent' => false,
			'conditions' => '',
			'fields' => '',
			'order' => '',
			'limit' => '',
			'offset' => '',
			'exclusive' => '',
			'finderQuery' => '',
			'counterQuery' => ''
		)
	);

}
